package cn.wolfcode.crm.domain;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Getter;
import lombok.Setter;
import org.springframework.format.annotation.DateTimeFormat;

import java.math.BigDecimal;
import java.util.Date;

@Getter@Setter
public class SaleAccount {

    @DateTimeFormat(pattern = "yyyy-MM-dd")//前台传后台的日期格式化
    @JsonFormat(pattern = "yyyy-MM-dd",timezone = "GMT+8")//后台传前台的日期格式化
    private Date vdate; //记账的时间
    private BigDecimal number;  //数量
    private BigDecimal costPrice;   //成本价格
    private BigDecimal costAmount;  //成本小计
    private BigDecimal salePrice;   //销售价格
    private BigDecimal saleAmount;  //销售的小计

    private Product product;    //商品
    private Employee employee;  //销售员
    private Client client;  //客户
}
